import java.io.File;
import java.io.IOException;
import java.text.ParseException;
import java.util.ArrayList;
import java.util.List;

import etxt2db.api.ClassificationExecutor;
import etxt2db.api.ClassificationModel;
import etxt2db.api.ClassificationModelCreator;


public class TestRegexAnnotator {
	public static void main(String[] args) throws IOException, ParseException{
		ClassificationModelCreator creator = new ClassificationModelCreator();
		//ClassificationModel an = creator.createRegexClassificationModel("Academy of Sciences|al-Jazeera|Al-Jazeera|Al-Qaeda|ANSA|Association of South East Asian Nations|Bank of England|British Chambers of Commerce|Bureau of Hygiene and Tropical Medicine|Campaign for Connecticut Families|C B I|CBI|C E C|CEC|C E E|CEE|Center for Retailing Studies|Central Elections Commission|Centre for Economic and Policy Research|Church of England|Church of Scotland|Communist Party|COMMUNIST PARTY|Confederation of British Industry|CONSERVATIVE PARTY|DATA CAPTURE AGENCY|Democratic Communist Party|DEMOCRATIC COMMUNIST PARTY|Democratic Left Alliance|Democratic Left Party|DEMOCRATIC LEFT PARTY|Department for Work and Pensions|DWP|EC|EEC|Electronics Research and Service Organization|EPSRC|EU|European Communities|European Community|European Union|Europol|Exchequer|Fatherland and Freedom|FIFA|Friends of the Earth|G8|General Agreement on Tariffs and Trade|Gulf Peace Team|GULF PEACE TEAM|Health and Hospitals Corporation|Her Majesty's Stationery Office|Hezbollah|HINA|Hong Kong Association of Banks|Hurriyat|Institute for Public Policy Research|Internet Corporation for Assigned Names and Numbers|Interpol|IPPR|IRA|Islamic Jihad|Japan Industrial Development Organization|Japan International Development Organization|Jewish Claims Conference|Jihad|Kosovo Liberation Army|Ku Klux Klan|LABOUR PARTY|Land Registry|LATCC|London Research Centre|Los Angeles County Fire Department|Major League Soccer|MPC|NAPP|NASCAR|National Academy of Sciences|Nato|NATO|Nats|NATS|Nazi|NBA|North Atlantic Treaty Organization|Northern Alliance|NTB|Oftel|Ohio state Supreme Court|Organization for Economic Cooperation and Development|Organization of Petroleum Exporting Peoples Progressive Left Protestant|RED PARTY|Revolutionary Armed Forces of Colombia|Russian Space Agency|Sinn Fein|SLD|SSL|Star Alliance|State Law and Order Restoration Council|State Law and Order Restoration Council|Sudan People's Liberation Army|Taleban|Taliban|Texas A&M University|Tokyo Institute for Municipal Research|Trade Union Congress|UEFA|UK Atomic Energy Authority|U N|UN|UNDP|UNESCO|United Nations|UNSCOM|USDA|US Major League Soccer|World Development Movement|World Health Organisation|World Health Organization|World Trade Organisation|World Trade Organization|WTO","company");
		//ClassificationModel an = creator.createDictionaryClassificationModel(new File("./resources/daysDictionary"));
		ClassificationModel an = creator.createRegexClassificationModel("Monday|Tuesday|Wednesday|Thursday|Friday|Saturday|Sunday","day");
		
		
		List<String> attributes = new ArrayList<String>();
		attributes.add("day");
		
		File testing = new File("C:\\Users\\Goncalo\\Desktop\\tier3");
		//File testing = new File("./resources/test/");
		
		ClassificationExecutor tester = new ClassificationExecutor();
		System.out.println(tester.getClassifiedSegments(testing, 
				                   an, attributes));
	}
}
